/*
*  Copyright 2019-2020 Zheng Jie
*
*  Licensed under the Apache License, Version 2.0 (the "License");
*  you may not use this file except in compliance with the License.
*  You may obtain a copy of the License at
*
*  http://www.apache.org/licenses/LICENSE-2.0
*
*  Unless required by applicable law or agreed to in writing, software
*  distributed under the License is distributed on an "AS IS" BASIS,
*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*  See the License for the specific language governing permissions and
*  limitations under the License.
*/
package com.fzhucc.modules.sciTechnologyDemand.domain;

import com.fzhucc.base.BaseEntity;
import lombok.Data;
import cn.hutool.core.bean.BeanUtil;
import io.swagger.annotations.ApiModelProperty;
import cn.hutool.core.bean.copier.CopyOptions;
import org.hibernate.annotations.Comment;
import org.hibernate.annotations.CreationTimestamp;

import javax.persistence.*;
import javax.validation.constraints.*;
import java.io.Serializable;
import java.sql.Timestamp;

/**
* @website https://eladmin.vip
* @description /
* @author yyg
* @date 2023-11-28
**/
@Entity
@Data
@Table(name="tb_sci_technology_demand")
public class SciTechnologyDemand extends BaseEntity implements Serializable {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "`id`")
    @ApiModelProperty(value = "id")
    private Integer id;

    @Column(name = "`qy_id`")
    @ApiModelProperty(value = "劳模需求企业表id")
    private Integer qyId;

    @Column(name = "`company_name`")
    @ApiModelProperty(value = "企业名称")
    private String companyName;

    @Column(name = "`registration_time`")
    @ApiModelProperty(value = "成立时间")
    private String registrationTime;

    @Column(name = "send_qz_time")
    @ApiModelProperty(value = "成功发送全总数据时间，发送成功才会记录")
    private Timestamp sendQzTime;

    @Column(name = "send_qz_qy_time")
    @ApiModelProperty(value = "成功发送全总企业信息数据时间，发送成功才会记录")
    private Timestamp sendQzQyTime;

    @Column(name = "`company_type`")
    @ApiModelProperty(value = "企业类型  zqx_company_type")
    private String companyType;

    @Column(name = "`business_license`")
    @ApiModelProperty(value = "统一社会信用代码")
    private String businessLicense;

    @Column(name = "`company_area`")
    @ApiModelProperty(value = "企业所在区域  zqx_company_area")
    private String companyArea;

    @Column(name = "`keyword`")
    @ApiModelProperty(value = "关键字;隔开")
    private String keyword;

    @Column(name = "`keyword_other`")
    @ApiModelProperty(value = "关键字其他填写")
    private String keywordOther;

    @Column(name = "`contacts`")
    @ApiModelProperty(value = "联系人姓名")
    private String contacts;

    /*@Column(name = "`record`")
    @ApiModelProperty(value = "记录")
    private String record;*/

    @Column(name = "`job_title`")
    @ApiModelProperty(value = "职务")
    private String jobTitle;

    @Column(name = "`contact_way`")
    @ApiModelProperty(value = "联系手机")
    private String contactWay;

    @Column(name = "`email`")
    @ApiModelProperty(value = "电子邮箱")
    private String email;

    @Column(name = "`address`")
    @ApiModelProperty(value = "通讯地址")
    private String address;

    @Column(name = "`details`")
    @ApiModelProperty(value = "企业简介")
    private String details;

    @Column(name = "`first_finisher_name`")
    @ApiModelProperty(value = "本企业劳模、工匠情况姓名")
    private String firstFinisherName;

    @Column(name = "`unit_position`")
    @ApiModelProperty(value = "本企业劳模、工匠情况职务")
    private String unitPosition;

    @Column(name = "`ma_type`")
    @ApiModelProperty(value = "本企业劳模、工匠情况劳模工匠人才类型zqx_ma_type")
    private String maType;

    @Column(name = "`technology`")
    @ApiModelProperty(value = "所需技术领域  zqx_technology")
    private String technology;

    @Column(name = "`review`")
    @ApiModelProperty(value = "回顾")
    private String review;

    @Column(name = "`slogan`",nullable = false)
    @NotBlank
    @ApiModelProperty(value = "需求名称")
    private String slogan;

    @Column(name = "`do_status`",nullable = false)
    @NotBlank
    @ApiModelProperty(value = "办理状态 默认匹配中 匹配中、已匹配、已解决")
    private String doStatus;

    @Column(name = "`retype`")
    @ApiModelProperty(value = "需求类别 zqx_re_type")
    private String retype;

    @Column(name = "`user_id`",nullable = false)
    @ApiModelProperty(value = "用户id")
    public Long userId;

    @Column(name = "`honor`")
    @ApiModelProperty(value = "需求描述")
    private String honor;

    @Column(name = "`pic`")
    @ApiModelProperty(value = "封面")
    private String pic;

    @Column(name = "`is_delete`",nullable = false)
    @ApiModelProperty(value = "是否删除默认否")
    private Integer isDelete;

    @Column(name = "`is_edit`",nullable = false)
    @ApiModelProperty(value = "是否允许编辑默认否")
    private Integer isEdit;

    @Column(name = "`org_area`",nullable = false)
    @ApiModelProperty(value = "地区组织机构区分  字典 zqx_org_area")
    private String orgArea;

    @Column(name = "`audit_status`",nullable = false)
    @ApiModelProperty(value = "审核状态 默认待审核  zqx_audit_status")
    private String auditStatus;


    @Column(name = "`is_show`",nullable = false)
    @NotNull
    @ApiModelProperty(value = "是否小程序h5展示 默认不展示")
    private Integer isShow;

    @Column(name = "`sort`",nullable = false)
    @NotNull
    @ApiModelProperty(value = "排序")
    private Integer sort;

    @Column(name = "`hot`",nullable = false)
    @NotNull
    @ApiModelProperty(value = "热度")
    private Integer hot;

    @Column(name = "`zscq`")
    @ApiModelProperty(value = "知识产权数量")
    private Integer zscq;

    @Column(name = "`jjxc`")
    @ApiModelProperty(value = "解决企业现场技术问题数量")
    private Integer jjxc;

    @Column(name = "`tsjn`")
    @ApiModelProperty(value = "提升职工技能水平的职工数数量")
    private Integer tsjn;

    @Column(name = "`cxcg`")
    @ApiModelProperty(value = "创新成果数量")
    private Integer cxcg;

    @Column(name = "`cz`")
    @ApiModelProperty(value = "产值")
    private String cz;

    @Column(name = "`profit`")
    @ApiModelProperty(value = "利润")
    private String profit;


    @Column(name = "`yq`")
    @ApiModelProperty(value = "企业所在园区")
    private String yq;

    @Column(name = "`is_zxw`")
    @ApiModelProperty(value = "是否为中小微企业")
    private String isZxw;

    @Column(name = "`is_zj`")
    @ApiModelProperty(value = "是否为专精特新企业")
    private String isZj;

    @Column(name = "`join_model_counts`")
    @ApiModelProperty(value = "参加劳模工匠人次")
    private String joinModelCounts;

    @Column(name = "`jj_problem_type`")
    @ApiModelProperty(value = "解决问题和开展服务类别")
    private String jjProblemType;

    @Column(name = "`yjj_problem_context`")
    @ApiModelProperty(value = "已解决问题主要内容")
    private String yjjProblemContext;

    @Column(name = "`xy`")
    @ApiModelProperty(value = "产生或预期产生效益(万元)")
    private String xy;

    @Column(name = "`data_id`")
    @ApiModelProperty(value = "工信厅唯一码")
    private String dataId;

    @Column(name = "`xqlb_other`")
    @ApiModelProperty(value = "其他需求列别  工信厅提供")
    private String xqlbOther;

    @Column(name = "`handle_type`")
    @ApiModelProperty(value = "工信厅 1-匹配推送，2-线下解决，3-其他")
    private Integer handleType;

    @Column(name = "`handle_desc`")
    @ApiModelProperty(value = "工信厅  处理说明")
    private String handleDesc;


    @Column(name = "delete_time")
    @ApiModelProperty(value = "假删除时间")
    private Timestamp deleteTime;


    public void copy(SciTechnologyDemand source){
        BeanUtil.copyProperties(source,this, CopyOptions.create().setIgnoreNullValue(true));
    }
}
